package com.ruoyi.common.enums;

/**
 * 房源查询方式
 *
 */
public enum SelectRoomTypeEnum {

    HEAT_NUMBER("1", "供热号查询"), CONSUMER("2", "搜索查询");

    private final String code;
    private final String info;

    SelectRoomTypeEnum(String code, String info) {
        this.code = code;
        this.info = info;
    }

    public String getCode() {
        return code;
    }

    public String getInfo() {
        return info;
    }

    public static SelectRoomTypeEnum getSelectRoomTypeEnum(String code) {
        SelectRoomTypeEnum userTypeEnum = null;
        for (SelectRoomTypeEnum value : values()) {
            if (code.equals(value.getCode())) {
                userTypeEnum = value;
            }
        }
        return userTypeEnum;
    }

}
